package com.sky.service;

import com.sky.dto.*;
import com.sky.entity.Orders;
import com.sky.result.PageResult;
import com.sky.vo.*;

import java.time.LocalDate;

public interface OrderService {
    //用户下单
    OrderSubmitVO submit(OrdersSubmitDTO ordersSubmitDTO);

    /**
     * 订单支付
     * @param ordersPaymentDTO
     * @return
     */
    OrderPaymentVO payment(OrdersPaymentDTO ordersPaymentDTO) throws Exception;

    /**
     * 支付成功，修改订单状态
     * @param outTradeNo
     */
    void paySuccess(String outTradeNo);

    //历史订单查询
    PageResult historyOrders(OrdersPageQueryDTO ordersPageQueryDTO);

    //历史订单详情页
    OrderVO orderInformation(Long id);

    //取消订单
    void cancelOrder(OrdersCancelDTO ordersRejectionDTO);

    //再来一单
    void repetitionOrder(Long id);

    //催单
    void reminderOrder(Long id);

    //各个订单状态搜索
    OrderStatisticsVO orderStatistics();

    //接单
    void confirmOrder(OrdersConfirmDTO ordersConfirmDTO);

    //拒单
    void rejectionOrder(OrdersRejectionDTO ordersRejectionDTO) throws Exception;

    //派送订单
    void deliveryOrder(Long id);

    //完成订单
    void completeOrder(Long id);

    //查询订单详情
    OrderVO checkOrderById(Long id);


}
